package jmine.tec.rpc.server.representation.representers;

import jmine.tec.rpc.server.representation.RepresentationContext;
import bancosys.tec.persist.base.enumx.StringValuedEnum;

/**
 * {@link AbstractRepresenter} que representa um apache {@link StringValuedEnum} em {@link String}
 * 
 * @author takeshi
 */
public class ApacheEnumAsStringRepresenter extends AbstractRepresenter<String, StringValuedEnum> {

    /**
     * C'tor
     */
    public ApacheEnumAsStringRepresenter() {
        super(String.class, StringValuedEnum.class);
    }

    /**
     * {@inheritDoc}
     */
    public String represent(RepresentationContext context, StringValuedEnum object) {
        return object.getValue();
    }

}
